import request from '@/utils/request'

export default {
  // 需求跟踪单明细
  // detail(params) {
  //   return request({
  //     url: `/v1/purchase-demand/purchase-demand-sku/detail`,
  //     method: 'get',
  //     params
  //   })
  // },
  detail(data) {
    return request({
      url: `v1/purchase-demand/purchase-demand-sku/get-select-detail`,
      method: 'post',
      data
    })
  },
  // 变更options
  getChangeOption(params) {
    return request({
      url: `v1/purchase-demand/purchase-demand-change/get-change-option`,
      method: 'post',
      params
    })
  },
  // 需求跟踪单变更
  change(data) {
    return request({
      url: `/v1/purchase-demand/purchase-demand-sku/change`,
      method: 'post',
      data
    })
  },
  // 编辑备库需求变更单
  edit(data) {
    return request({
      url: `/v1/purchase-demand/purchase-demand-change/edit`,
      method: 'post',
      data
    })
  },
  // 获取 关联的备料计划
  getPlan(data) {
    return request({
      url: `/v1/purchase-demand/purchase-demand/get-plan`,
      method: 'post',
      data
    })
  },
}
